package edu.cmu.javadb;

import java.util.Collection;

import edu.cmu.javadb.plan.PlanNode;
import edu.cmu.javadb.plan.visitor.ExecutionVisitor;

public class Engine {
	
	static private Engine engine = new Engine();
	
	private Engine() {
		
	}
	
	static public Engine getInstance() {
		return engine;
	}
	
	public Collection<?> execute(PlanNode plan) {
		return plan.accept(new ExecutionVisitor());
	}
}
